package com.greenold.order.domain;

import java.math.BigDecimal;
import java.util.Date;


import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.greenold.common.annotation.Excel;
import com.greenold.common.core.domain.BaseEntity;

/**
 * 订单对象 order
 * 
 * @author ruoyi
 * @date 2025-10-13
 */
public class Order extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** $column.columnComment */
    @Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
    private String id;

    /** 业务系统订单号 */
    @Excel(name = "业务系统订单号")
    private String bizOrderNo;


    /** 服务老人ID */
    @Excel(name = "服务老人ID")
    private String serviceElderId;
    /** 老人姓名 */
    @Excel(name="老人姓名")
    private String serviceElderName;
    @Excel(name="客人姓名")
    private String customerName;


    /** 床位号 */
    @Excel(name = "床位号")
    private String extend1;

    /** 服务项目id */
    @Excel(name = "服务项目id")
    private String serviceItemId;

    /** 订单金额(元) */
    @Excel(name = "订单金额(元)")
    private BigDecimal amount;

    /** 预计服务时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "预计服务时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date expectedServiceTime;

    /** 客户id */
    @Excel(name = "客户id")
    private String customerId;

    /** 创建时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date createdAt;

    /** 订单状态（0.待支付 1.待执行 2.已执行 3.已完成 4.已关闭 5.已退款） */
    @Excel(name = "订单状态", readConverterExp = "0=.待支付,1=.待执行,2=.已执行,3=.已完成,4=.已关闭,5=.已退款")
    private String orderStatus;

    /** 交易状态（1.未付 2.已付 3.已关闭） */
    @Excel(name = "交易状态", readConverterExp = "0=.未支付,1=.已支付,2=.已关闭,3=退款失败,4= 退款成功")
    private String payStatus;

    /** 是否有退款(0  否 1是 ) */
    private Integer hasRefund;

    /** 交易系统订单号 */
    private String tradeOrderNo;

    /** 退款金额 */
    private BigDecimal refundAmount;

    /** $column.columnComment */
    private String cancelReason;

    /** $column.columnComment */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date updatedAt;

    /** $column.columnComment */
    private String createdBy;

    /** $column.columnComment */
    private String updatedBy;

    /** 是否可见（0.可见 1.不可见） */
    private String visible;

    /** 取消人类型（1.前台 2.后台） */
    private String cancelByType;
    /** 备注 */
    private String remark;


    /** 扩展字段2 */
    private String extend2;
    public String getServiceElderName() {
        return serviceElderName;
    }

    public void setServiceElderName(String serviceElderName) {
        this.serviceElderName = serviceElderName;
    }
    public String getCustomerName() {
        return customerName;
    }
    public void setCustomerName(String customerName) {
        this.customerName = customerName;
    }



    public void setId(String id) 
    {
        this.id = id;
    }

    public String getId() 
    {
        return id;
    }

    public void setBizOrderNo(String bizOrderNo) 
    {
        this.bizOrderNo = bizOrderNo;
    }

    public String getBizOrderNo() 
    {
        return bizOrderNo;
    }

    public void setServiceElderId(String serviceElderId)
    {
        this.serviceElderId = serviceElderId;
    }

    public String getServiceElderId()
    {
        return serviceElderId;
    }

    public void setExtend1(String extend1) 
    {
        this.extend1 = extend1;
    }

    public String getExtend1() 
    {
        return extend1;
    }

    public void setServiceItemId(String serviceItemId) 
    {
        this.serviceItemId = serviceItemId;
    }

    public String getServiceItemId() 
    {
        return serviceItemId;
    }

    public void setAmount(BigDecimal amount) 
    {
        this.amount = amount;
    }

    public BigDecimal getAmount() 
    {
        return amount;
    }

    public void setExpectedServiceTime(Date expectedServiceTime) 
    {
        this.expectedServiceTime = expectedServiceTime;
    }

    public Date getExpectedServiceTime() 
    {
        return expectedServiceTime;
    }

    public void setCustomerId(String customerId) 
    {
        this.customerId = customerId;
    }

    public String getCustomerId() 
    {
        return customerId;
    }

    public void setCreatedAt(Date createdAt) 
    {
        this.createdAt = createdAt;
    }

    public Date getCreatedAt() 
    {
        return createdAt;
    }

    public void setOrderStatus(String orderStatus) 
    {
        this.orderStatus = orderStatus;
    }

    public String getOrderStatus() 
    {
        return orderStatus;
    }

    public void setPayStatus(String payStatus) 
    {
        this.payStatus = payStatus;
    }

    public String getPayStatus() 
    {
        return payStatus;
    }

    public void setHasRefund(Integer hasRefund) 
    {
        this.hasRefund = hasRefund;
    }

    public Integer getHasRefund() 
    {
        return hasRefund;
    }

    public void setTradeOrderNo(String tradeOrderNo) 
    {
        this.tradeOrderNo = tradeOrderNo;
    }

    public String getTradeOrderNo() 
    {
        return tradeOrderNo;
    }

    public void setRefundAmount(BigDecimal refundAmount) 
    {
        this.refundAmount = refundAmount;
    }

    public BigDecimal getRefundAmount() 
    {
        return refundAmount;
    }

    public void setCancelReason(String cancelReason) 
    {
        this.cancelReason = cancelReason;
    }

    public String getCancelReason() 
    {
        return cancelReason;
    }

    public void setUpdatedAt(Date updatedAt) 
    {
        this.updatedAt = updatedAt;
    }

    public Date getUpdatedAt() 
    {
        return updatedAt;
    }

    public void setCreatedBy(String createdBy) 
    {
        this.createdBy = createdBy;
    }

    public String getCreatedBy() 
    {
        return createdBy;
    }

    public void setUpdatedBy(String updatedBy) 
    {
        this.updatedBy = updatedBy;
    }

    public String getUpdatedBy() 
    {
        return updatedBy;
    }

    public void setVisible(String visible) 
    {
        this.visible = visible;
    }

    public String getVisible() 
    {
        return visible;
    }

    public void setCancelByType(String cancelByType) 
    {
        this.cancelByType = cancelByType;
    }

    public String getCancelByType() 
    {
        return cancelByType;
    }

    public void setExtend2(String extend2) 
    {
        this.extend2 = extend2;
    }

    public String getExtend2() 
    {
        return extend2;
    }


    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("bizOrderNo", getBizOrderNo())
            .append("serviceElderId", getServiceElderId())
            .append("extend1", getExtend1())
            .append("serviceItemId", getServiceItemId())
            .append("amount", getAmount())
            .append("expectedServiceTime", getExpectedServiceTime())
            .append("customerId", getCustomerId())
            .append("createdAt", getCreatedAt())
            .append("orderStatus", getOrderStatus())
            .append("payStatus", getPayStatus())
            .append("hasRefund", getHasRefund())
            .append("tradeOrderNo", getTradeOrderNo())
            .append("refundAmount", getRefundAmount())
            .append("cancelReason", getCancelReason())
            .append("updatedAt", getUpdatedAt())
            .append("createdBy", getCreatedBy())
            .append("updatedBy", getUpdatedBy())
            .append("visible", getVisible())
            .append("cancelByType", getCancelByType())
            .append("remark", getRemark())
            .append("extend2", getExtend2())
                .append("serviceElderName", getServiceElderName())
                .append("customerName", getCustomerName())
            .toString();
    }
}
